<?php

namespace App\Http\Controllers\Api\Syj;

use App\Common\Responses;
use App\Http\Controllers\Controller;
use App\Utils\Service\Syj\Baidu;
use Illuminate\Http\Request;

class ChatController extends Controller
{
    //百度文本审核测试
    public function test(Request $request){
        $name = $request->post('name');
        $data = Baidu::TextRevew()->text($name);
        return Responses::success($data,200,'success');
    }
    //百度图片审核
    public function img(Request $request){
        $image = $request->file('image');
        //dd($image);
        $data = Baidu::TextRevew()->image($image);
        return Responses::success($data,200,'success');
    }
    //百度视频审核
    public function video(Request $request){
        $video = $request->file('video');
        $data = Baidu::TextRevew()->video($video);
        return Responses::success($data,200,'success');
    }
}
